{% extends "base.html" %}
{% block title %}{{task}}{% endblock %}
{% block more %}
    <li><a href="javascript:void(0);" onclick="deleteTask('{{task}}');">Delete Task</a></li>
{% endblock %}
{% block content %}
<div id="content">
<h2>Task: {{task}}</h2>
<form id="taskForm" action='javascript:void(0)'>
    <p>Task name: <br/><input type="text" name="name" value="{{task}}" />
    <p>Script: <br><textarea name="script" rows="20" cols="40">{{script}}</textarea>
    <p><input name="save" type="submit" value="Save" onclick="putUrlForm('/tasks/{{task}}', 'taskForm');">
</form>
{% if included != None and included|length > 0: %}
    <h3>Task included in jobs:</h3>
    <ul>
    {% for job in included: %}
        <li><a href="/jobs/{{job}}">{{job}}</a>
    {% endfor %}
    </ul>
{% endif %}
</div>
{% endblock %}